//
//  CardDeck.m
//  MemoPocker
//
//  Created by Jose Luis Ferreyra on 18/02/13.
//  Copyright (c) 2013 Dharma. All rights reserved.
//

#import "PlayingCardDeck.h"
#import "PlayingCard.h"

@implementation PlayingCardDeck

-(id)init
{
    self = [super init];
    if (self){
        for (NSString *suit in [PlayingCard validSuits]) {
            for (NSUInteger rank=1; rank <= [PlayingCard maxRank]; rank++)
            {
                PlayingCard *card = [[PlayingCard alloc] init];
                card.rank=rank;
                card.suit=suit;
                [self addCard:card  atTop:TRUE];
            }
        }
    }
    return self;
}

@end
